import { dispatch } from "rxjs/internal/observable/pairs";

const creator = (type, payload) => ({ type, payload })


export const changeName = (newName) => creator('CHANGE_NAME', newName)
// export const changeName = payload =>{
//     return dispatch(creator('CHANGE_NAME', payload))
// }